<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
       <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<!DOCTYPE html>
<html>
<head>
		<meta name="renderer" content="webkit">
		<meta charset="utf-8" />
		<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
		<title>恒达汽修有限公司</title>

		<link rel="stylesheet" type="text/css" href="css/meteinfo_ui.css" id="metuimodule" data-module="1" />
		<link rel="stylesheet" type="text/css" href="css/metinfo.css" />
		<script src="js/jQuery1.7.2.js" type="text/javascript"></script>
		<script src="js/metinfo_ui.js" type="text/javascript"></script>
		<script src="js/ch.js" type="text/javascript"></script>
		<script>
			$(function(){
				if($("#msg").val()=="1"){
					alert("ok");
					}
			})
		</script>
		<style type="text/css">
			html,
			body {
				margin: 0;
				padding: 0;
			}
			
			.iw_poi_title {
				color: #CC5522;
				font-size: 14px;
				font-weight: bold;
				overflow: hidden;
				padding-right: 13px;
				white-space: nowrap
			}
			
			.iw_poi_content {
				font: 12px arial, sans-serif;
				overflow: visible;
				padding-top: 4px;
				white-space: -moz-pre-wrap;
				word-wrap: break-word
			}
		</style>
		<!--[if IE]>
		<script src="public/js/html5.js" type="text/javascript"></script>
		<![endif]-->
	</head>

	<body>
	<input type="hidden" value="${msg }" id="msg">
		<div class="m-nav">
			<nav class="inner">
				<ul class="list-none">
					<li id="nav_10001" style='width:123px;'><a href='apiinfoAction!selectBegin' title='网站首页' class='nav'><span>网站首页</span></a></li>
					<li id='nav_1' style='width:123px;'><a href='about.jsp' title='关于我们' class='hover-none nav'><span>关于我们</span></a></li>
					<li id='nav_2' style='width:123px;'><a href='newsaction!findall.action' title='信息中心' class='hover-none nav'><span>信息中心</span></a></li>
					<li id='nav_3' style='width:123px;'><a href='apiinfoAction!selectPage?ye=1' title='恒达汽修产品' class='hover-none nav'><span>恒达汽修产品</span></a></li>
					<li id='nav_4' style='width:122px;'><a href='carsaction!findall_cars' title='服务车型' class='hover-none nav'><span>服务车型</span></a></li>
					<li id='nav_34' style='width:122px;' class='navdown'><a href='demandInfoAtion!queryAll' title='在线招聘' class='hover-none nav'><span>在线招聘</span></a></li>
					<li id='nav_11' style='width:122px;'><a href='booking.jsp' title='在线预约' class='hover-none nav'><span>在线预约</span></a></li>
					<li id='nav_18' style='width:122px;'><a href='contact.jsp' title='联系我们' class='hover-none nav'><span>联系我们</span></a></li>
				</ul>
			</nav>
		</div>

		

		<header>
			<div class="inner top">

				<a href="../" title="汽配公司" id="web_logo">
					<img src="img/1363847903.png" style="width: 210px; height: 55px;" alt="汽配公司" title="汽配公司" style="margin:0px 0px 0px 10px;" />
				</a>

				<div class="top-seo">
					<div class="tpseotxt">
						<p>
							&nbsp;020-5856-1762</p>
					</div>
				</div>
			</div>
		</header>

		<div class="inner met_flash">
			<div class="flash">
				<img src='img/1363850250.jpg' width='980' alt='' height='300'></div>
		</div>

		<div class="sidebar inner">
			

			<div class="sb_nav">

				<h3 class='title line'>联系方式</h3>
				<div class="active editor b-r">
					<div> 电话：020-5856-1762</div>
					<div> 手机：15521389512</div>
					<div> QQ：913405314</div>
					<div> 联系人：谭先生</div>
					<div> 邮箱：hengdaqixiu@163.com</div>
					<div> 邮编：404100</div>
					<div class="clear"></div>
				</div>

			</div>

			<div class='sb_box b-r'>
				<h3 class="title">
			<div class="position">当前位置：<a href="apiinfoAction!selectBegin" title="网站首页">网站首页</a> &gt; <a href="demandInfoAtion!queryAll" >在线招聘</a></div>
			<span>在线招聘</span>
		</h3>
				<div class="clear"></div>

				<form id="ff" action="${pageContext.request.contextPath }/candidateInfoAction!add.action" method='POST' enctype="enctype = "multipart/form-data">
						<table class='cv_table'>
							<tr>
								<td class='text'>面试职位</td>
								<td class='input'>
								<select name='ci.departId.departId' >
									<c:forEach items="${list }" var="list">
									     <option value="${list.departId}">${list.departName}</option>
									</c:forEach>
								</select>
								</td>
							</tr>
							<tr>
								<td class='text'>姓名:</td>
								<td class='input'><input name='ci.candName' type='text' class='input-text' size='40'><span class='info' id="name">*</span></td>
							</tr>
							<tr>
								<td class='text'>性别:</td>
								<td class='input'>
									<input name='ci.candSex' type='radio' id='para18' value='0' checked='checked' />
									<label for='para18'>男</label> 
									<input name='ci.candSex' type='radio' id='para28' value='1' />
									<label for='para28'>女</label> 
									<span class='info' id="sex">*</span><span></span></td>
							</tr>
							<tr>
								<td class='text'>年龄:</td>
								<td class='input'><input name='ci.candAge' type='number' class='input-text' size='40'><span class='info' id="candAge">*</span></td>
							</tr>
							<tr>
								<td class='text'>期望工资:</td>
								<td class='input'><input name='ci.candSalary' type='number' class='input-text' size='40'><span id="candSalary" class='info'>*</span></td>
							</tr>
							<tr>
								<td class='text'>电话:</td>
								<td class='input'><input name='ci.candPhone' type='text' class='input-text' size='40'><span id="candPhone" class='info'>*</span></td>
							</tr>
							<tr>
							    <td class='text'>住址:</td>
							    <td class='input'><textarea rows="2" cols="34" name="ci.candAddress"></textarea><span id="candAddress" class='info'>*</span></td>
							</tr>
							<input type="hidden" name="ci.candState" value="0">
							<tr>
							    <td class='text'>备注:</td>
							    <td class='input'><textarea rows="2" cols="34" name="ci.candRemark"></textarea><span id="candRemark" class='info'>*</span></td>
							</tr>
							<tr>
								<td class='text'></td>
								<td class='submint'>
								   <input id="btnSubmit" type='Submit' name='button' onclick="tj()" value='提交信息' class='submit button orange' />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
								   <input id="btnSubmit" type="reset" name='reset' value='重置信息' class='submit button orange' />
								</td>
							</tr>
						</table>
					</form>
<script type="text/javascript">
	function tj(){
		alert("提交成功");
		document.getElementById("ff").submit();
	}
</script>
			</div>
			<div class="clear"></div>
		</div>

		<footer class="inner" >
			<div class="foot-nav">
				<a href="about.jsp" 0 title='关于我们'>关于我们</a><span>
					|</span><a href='feedback.jsp' title='客户留言'>客户留言</a><span>|
					<span><a href='booking.jsp' title='在线预约'>在线预约</a><span>|
					</span><a href='demandInfoAtion!queryAll' title='人才招聘'>人才招聘</a><span>|
				<a href='contact.jsp' title='网站地图'>联系我们</a>
			</div>
			<div class="foot-text">
				<p>恒达汽修有限公司版权所有     2017-2018    备案号：渝ICP备13004606
				</p>
				<p>电话：020-5856-1762</p>
			</div>
		</footer>
				<script type="text/javascript" src="js/jquery-3.2.1.min.js" ></script>
		<script type="text/javascript">
			$(function(){
				$("#btnSubmit").click(function(){
					var name=$("input[name=candidateName]").val();
					var phone=$("input[name=telephone]").val();
					var number=$("input[name=number]").val();
					
					var myreg = /^(((13[0-9]{1})|(15[0-9]{1})|(18[0-9]{1}))+\d{8})$/; 
					if(name==""){
						$("#name").text("请输入姓名");
						return false; 
					}
					if(candAge==""){
						$("#candAge").text("请输入年龄");
						return false; 
					}
					if(candSalary==""){
						$("#candSalary").text("请输入期望工资");
						return false; 
					}
					if(candPhone==""){
						$("#candPhone").text("请输入电话");
						return false; 
					}
					if(candAddress==""){
						$("#candAddress").text("请输入地址");
						return false; 
					}
					
					
					$("#name").text("");
					if(!myreg.test(phone)) 
					{ 
					   $("#phone").text("请输入有效的手机号码！");
					    return false; 
					}  $("#phone").text("");
					
					//判断身份证号码有效性
						//获取身份证号
					
					var flagIDCard =isCardNo(number);
					if(flagIDCard==false){
						$("#idCardNo").text("身份证输入不合法！");
						return false;
					}
					$("#idCardNo").text("");
				
					//可以提交
					//$("#frmAddCandidateInfo").submit();
					
				});
				
			});
	
	
	//正则表达式判断身份证是否合法
	function isCardNo(card)  
      {  
      	
      // 身份证号码为15位或者18位，15位时全为数字，18位前17位为数字，最后一位是校验位，可能为数字或字符X  
      var reg = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/;  
     	if(reg.test(card) === false)  
   			{  
       return  false;  
  		 }  
   
	}  
	</script>	
</body>
</html>